package com.xiaoma.thread.executors;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

/**
 * @author xiaomacdut
 * @date 2020年3月4日 下午3:48:17
 */
public class ExecutorsTest{
    
    public static void main(String [] args){
        
        ExecutorService newCachedThreadPool = Executors.newCachedThreadPool();
        // ExecutorService newCachedThreadPool1 = Executors.newCachedThreadPool();
        
        
        Thread thread = new Thread(){
            
            public void run(){
                System.out.println("asdfasd");
            }
        };
        
        newCachedThreadPool.execute(thread);
        newCachedThreadPool.shutdown();
    }
}
